package com.newsproject.pojo;


import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class Comment {
    private int commentId;
    private int userId;
    private int postId;
    private String content;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createdTime;
    private Integer parentId;
    private int likeCount;//存储评论点赞数
    private List<Comment> replies; // 存储子回复
    private String userName ;// 评论的用户名
    private String avatar ; // 评论的用户头像


}
